package com.lin.app.service;

import com.lin.springframework.Autowired;
import com.lin.springframework.Component;

@Component
public class AService implements IAService{

    @Autowired
    private IBService BService;

    @Override
    public void say() {
        System.out.println("I'm A， My B is"+BService.toString());
    }

    public AService() {
        System.out.println("创建A");
    }


    @Override
    public String toString() {
        return "InstanceA{" +
                "instanceB=" + BService +
                '}';
    }
}
